- main_toolbar do |t|
  = t.edit resource
  = t.renew(resource, method: :post) if current_user.can?(:write, :sales) && resource.renewable?
  - if resource.suspendable?
    = t.suspend resource, method: :post
  - elsif resource.suspended
    = t.takeover resource, method: :post
  = t.destroy if resource.destroyable_by_user?

= main_informations do
  = infos do
    = resource_info :nature do |nature|
      = link_to(nature.name, {controller: :subscription_natures, action: :show, id: nature.id})
    = resource_info :started_on
    = resource_info :stopped_on
  = attributes_list(resource) do |l|
    - l.attribute :subscriber, url: true
    - l.attribute :address
    - l.attribute :sale, url: true if resource.sale
    - l.attribute :quantity
    - l.attribute :suspended
    - l.attribute :parent, url: true if resource.parent
    -# if resource.children.any?
      %dl
        %dt= resource.human_attribute_name(:children)
        %dd= resource.children.map { |s| link_to(s.number, { id: s.id }) }.to_sentence.html_safe
